package com.example.newsmanager.entity.DTO;

import jakarta.validation.constraints.Email;
import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import lombok.Data;

@Data
public class UpdatePassword {
    @NotNull(message = "密码不能为null")
    @NotEmpty(message = "密码不能为空")
    @Size(min = 6, max = 14, message = "密码在6-14位之间")
    private String password;


    @NotNull(message = "邮箱不能为null")
    @NotEmpty(message = "邮箱不能为空")
    @Email
    private String email;

    @NotNull(message = "验证码不能为null")
    @NotEmpty(message = "验证码不能为空")
    @Size(min = 4, max = 4, message = "验证码必须为4位")
    private String code;
}
